﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;

/// <summary>
/// Transform物体节点的组件
/// </summary>
public class TransformUnitComponent : MonoBehaviour {

    [SerializeField]
    UIItemTransformUnitComponent uiComponent;
    public Vector3 zeroPosition;
    public Vector3 minPosition;

    public UIItemTransformUnitComponent UiComponent
    {
        get
        {
            return uiComponent;
        }

        set
        {
            uiComponent = value;
        }
    }

    public void Show(UIItemTransformUnitComponent uiComponent, Vector3 zeroPosition, Vector3 minPosition)
    {
		this.uiComponent = uiComponent;
		this.zeroPosition = zeroPosition;
		this.minPosition = minPosition;
    }
    public void SetPositionX(float x)
    {
        this.uiComponent.SetPositionX(x);
    }
    public void SetPositionY(float y)
    {
        this.uiComponent.SetPositionY(y);
    }
    public void SetPositionZ(float z)
    {
        this.uiComponent.SetPositionZ(z);
    }
    public void SetPosition(Vector3 v)
    {
        this.uiComponent.Position = v;
    }

}
